﻿namespace EyeOpen.SilverlightConverter
{
    using System;
    using System.Xml.Linq;

    public partial class VisualStudioProjectConverter
    {
        public XElement GetConverted(VisualStudioProject visualStudioProject)
        {
            if (!visualStudioProject.IsSilvelightLibrary)
            {
                return this.ConvertWindowsLibraryToSilverlight(visualStudioProject.ProjectXElement);
            }
            else
            {
                throw new NotSupportedException("Actually this class can only convert Windows Library to Silverlight Library, not viceversa.");
            }
        }
    }
}